home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / win-fort.zip / INITFWC.FOR < prev    next >
Text File  |  1991-11-09  |  2KB  |  47 lines

  1. $DEFINE GDI
  2. $DEFINE USER
  3. $DEFINE WINSTYLES
  4.       INCLUDE 'WINDOWS.FI'
  5.  
  6.       FUNCTION InitFWClock(hInstance)
  7.       IMPLICIT NONE
  8. C
  9. C Author       : Kevin B Black
  10. C Date written : 23-Oct-1991
  11. C Abstract     :
  12. C
  13. C Initializes window data and registers window class
  14. C
  15.  
  16.       INTEGER*2 InitFWClock
  17.       INTEGER*2 hInstance             ! Current instance
  18.  
  19.       INCLUDE 'WINDOWS.FD'
  20.       EXTERNAL FWClockWndProc
  21.       INCLUDE 'FWCLOCK.FD'
  22.  
  23.       RECORD /WNDCLASS/ WC
  24.  
  25. C
  26. C Fill in window class structure with parameters that describe the
  27. C main window. Register the FWClock window class.
  28. C
  29.       WC.STYLE=NULL                                 ! Class style(s).
  30.       WC.lpfnWndProc=LOCFAR(FWClockWndProc)         ! Function to retrieve messages for
  31.                                                     ! windows of this class.
  32.       WC.cbClsExtra=0                               ! No per-class extra data.
  33.       WC.cbWndExtra=0                               ! No per-window extra data.
  34.       WC.hInstance=hInstance                        ! Application that owns the class.
  35.       WC.hIcon=NULL                                 ! Icon is internal
  36.       WC.hCursor=LoadCursor_A(NULL, IDC_ARROW)      ! Loads default cursor
  37.       WC.hbrBackground=NULL
  38.       WC.lpszMenuName=LOCFAR('FWClockMenu'C)        ! Name of menu resource in .RC file.
  39.       WC.lpszClassName=LOCFAR('FWClockWClass'C)     ! Name used in call to CreateWindow.
  40.       WC.style= CS_VREDRAW.OR.CS_HREDRAW.OR.CS_BYTEALIGNCLIENT
  41. C
  42. C Register the window class and return success/failure code.
  43. C
  44.       InitFWClock=RegisterClass(WC)
  45.       RETURN
  46.       END
  47.